package com.api.shopapi.service.impl;

import com.api.shopapi.entity.CashierCartGoodsPrice;
import com.api.shopapi.entity.dto.CashierCartGoodsPriceDTO;
import com.api.shopapi.mapper.CashierCartGoodsPriceMapper;
import com.api.shopapi.service.CashierCartGoodsPriceService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("CashierCartGoodsPriceServiceImplOne")
public class CashierCartGoodsPriceServiceImpl implements CashierCartGoodsPriceService {
    @Autowired
    private CashierCartGoodsPriceMapper cashierCartGoodsPriceMapper;
    @Override
    public int insert(CashierCartGoodsPrice cashierCartGoodsPrice) {
        return cashierCartGoodsPriceMapper.insert(cashierCartGoodsPrice);
    }

    @Override
    public int delete(String cashierCartGoodsPriceCode) {
        return cashierCartGoodsPriceMapper.delete(cashierCartGoodsPriceCode);
    }

    @Override
    public int update(CashierCartGoodsPrice cashierCartGoodsPrice) {
        return cashierCartGoodsPriceMapper.update(cashierCartGoodsPrice);
    }

    @Override
    public List<CashierCartGoodsPrice> getList() {
        return cashierCartGoodsPriceMapper.getList();
    }

    @Override
    public CashierCartGoodsPrice getByCashierCartGoodsPriceCode(String cashierCartGoodsPriceCode) {
        return cashierCartGoodsPriceMapper.getByCashierCartGoodsPriceCode(cashierCartGoodsPriceCode);
    }

    @Override
    public CashierCartGoodsPriceDTO getByCashierCartGoodsCode(String cashierCartGoodsCode){
        return cashierCartGoodsPriceMapper.getByCashierCartGoodsCode(cashierCartGoodsCode);
    }

}
